<!--
 * @Author: H.
 * @Date: 2021-08-09 18:38:23
 * @LastEditTime: 2021-11-24 17:11:24
 * @Description: 
-->
<template>
  <div>
    <h1>Tabs 示例</h1>
    <Demo :component="Tab1Demo" />
    <h2>Tabs Attributes</h2>
    <Table :dataSource="dataSource" :columns="columns" />
  </div>
</template>

<script lang="ts">
import Demo from './Demo/index.vue'
import Tab1Demo from './Demo/Tab1.demo.vue'
import Table from '../lib/table/Table.vue'

export default {
  components: {
    Demo,
    Table,
  },
  setup(props) {
    const dataSource = [
      {
        id: 1,
        params: 'v-model:selected',
        illustrate: 'Tabs的绑定值，选中选项卡的 title',
        type: 'string',
        optional: '-',
        defaults: '-',
      },
      {
        id: 2,
        params: 'title',
        illustrate: 'Tab标签的名字',
        type: 'string',
        optional: '-',
        defaults: '-',
      },
    ]
    const columns = [
      { title: '参数', prop: 'params', width: '300' },
      { title: '说明', prop: 'illustrate', width: '300' },
      { title: '类型', prop: 'type', width: '100' },
      { title: '可选值', prop: 'optional', width: '100' },
      { title: '默认值', prop: 'defaults' },
    ]
    return {
      Tab1Demo,
      dataSource,
      columns,
    }
  },
}
</script>

<style></style>
